/**
 * Open it service management
 */
package com.oitsm.dispatcher.task;

import com.oitsm.dispatcher.Context;

/**
 * 任务
 * @author Arab Runner
 * Jul 24, 2011 1:27:09 PM
 */
public abstract class Tasker implements Runnable{
	private String id;
	private long createTime;
	private long startTime;
	private long endTime;
	
	private Context ctx = new Context();
	
	public Tasker(){
		this.createTime = System.currentTimeMillis();
	}
	
	abstract public void run();

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public long getCreateTime() {
		return createTime;
	}

	public void setCreateTime(long createTime) {
		this.createTime = createTime;
	}

	public long getStartTime() {
		return startTime;
	}

	public void setStartTime(long startTime) {
		this.startTime = startTime;
	}

	public long getEndTime() {
		return endTime;
	}

	public void setEndTime(long endTime) {
		this.endTime = endTime;
	}

	public Context getCtx() {
		return ctx;
	}

	public void setCtx(Context ctx) {
		this.ctx = ctx;
	}
}
